home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c++-part2 / 15294 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  1.0 KB

  1. Path: newsfeed.internetmci.com!iol!usenet
  2. From: David Byrden <Goyra@iol.ie>
  3. Newsgroups: comp.lang.c++
  4. Subject: Re: Assignment op. for an object with reference member
  5. Date: 4 Apr 1996 18:19:23 GMT
  6. Organization: Ireland On-Line
  7. Message-ID: <4k13rb$gkh@nuacht.iol.ie>
  8. References: <3163FE18.28D@dbsoftware.com>
  9. NNTP-Posting-Host: dialup-209.dublin.iol.ie
  10. Mime-Version: 1.0
  11. Content-Type: text/plain; charset=us-ascii
  12. Content-Transfer-Encoding: 7bit
  13. X-Mailer: Mozilla 1.22KIT (Windows; I; 16bit)
  14.  
  15. Guru Chandar <GCHAN@dbsoftware.com> wrote:
  16.  
  17. >I have two questions:
  18. >
  19. >1. Is it legel to even attempt to change a reference after it is initialized?
  20.  
  21.  
  22.                  No. You are not allowed to change it.
  23.  
  24.  
  25. >
  26. >2. is the code given above, especially the
  27. >   syntax to invoke the copy constructor explicitly on an object: 
  28. >
  29. >     this->B::B(src); 
  30. >   
  31. >   valid? Is it supported in the standard? 
  32.  
  33.  
  34.                   No.
  35.  
  36.  
  37.         You should use a pointer, because you want to change it.
  38.  
  39.  
  40.                                               David
  41.  
  42.  
  43.